using UnityEngine;
using System.Collections;

public class Meteor_Gran_Ray : MonoBehaviour {
	
	private GameObject point;
	public GameObject Shoots;
	public string my_tag;
	public float TimeToInstantiate;
	private float timer = 0.0f;
	//Raio, Meteoro e Granizo
	// Use this for initialization
	void Awake ()
	{
		point = gameObject;
		print (point.transform.position);
	}
	
	void Start () {
	     
		 
	}
	
	// Update is called once per frame
	void Update () 
	{
		timer += Time.deltaTime;
	
		
		if(timer >= TimeToInstantiate)
		{
			Shoots.tag = my_tag;
		    Instantiate(Shoots,point.transform.position,Quaternion.identity);
			timer = 0.0f;
		}
	}
}
